<!DOCTYPE html>
<html>

<head>
    <meta charset="utf-8">
    <meta name="viewport" content="width=device-width, initial-scale=1.0,maximum-scale=1.0, user-scalable=0">
    <title>充值</title>
    <link href="__PUBLIC__/AmazeUI-2.4.2/assets/css/admin.css" rel="stylesheet" type="text/css">
    <link href="__PUBLIC__/AmazeUI-2.4.2/assets/css/amazeui.css" rel="stylesheet" type="text/css">
    <link href="__PUBLIC__/css/personal.css" rel="stylesheet" type="text/css">
    <link href="__PUBLIC__/css/stepstyle.css" rel="stylesheet" type="text/css">
    <script type="text/javascript" src="__PUBLIC__/js/jquery-1.7.2.min.js"></script>
    <script src="__PUBLIC__/AmazeUI-2.4.2/assets/js/amazeui.js"></script>
    <style type="text/css">
        body {
            /*background-color: #fff;*/
        }
        .cash_div{
            background-color: #fff;
            margin-top: 2%;
            margin-bottom: 3%;

        }

        .cash_input{

            width: 100%;
            height: 35px;
            font-size: 15px;
            padding-left: 4%;
            border:0;
        }

        ::-webkit-input-placeholder { /* WebKit browsers */
            color:    #5c5c5c;
            font-size: 15px;
        }
        :-moz-placeholder { /* Mozilla Firefox 4 to 18 */
            color:    #5c5c5c;
            font-size: 15px;
        }
        ::-moz-placeholder { /* Mozilla Firefox 19+ */
            color:    #5c5c5c;
            font-size: 15px;
        }
        :-ms-input-placeholder { /* Internet Explorer 10+ */
            color:    #5c5c5c;
            font-size: 15px;
        }

    </style>
</head>

<body>
<div class="center">
    <div class="">
        <div >

            <form >
                <div class="cash_div">
                    <!--<div class="am-form-group">-->
                    <!--<label for="money" style="font-size: 18px;font-weight: bold;margin-bottom: 10px;"></label>-->
                    <span style="font-size: 15px;color: #5c5c5c;padding-left: 4%">充值金额</span>
                    <span style="position: relative;right: 19%;top:56px;font-size: 35px">￥</span>

                    <div style="margin-left: 10%;margin-top: 4%; margin-bottom: 4%">
                        <input type="number" style="height: 35px;font-size: 35px;border-bottom:solid;border-bottom-color: #999;border-bottom-width:1px" class="cash_input" id="money" name="money" />
                    </div>
                    <span id="info"  style="font-size: 15px;color: #5c5c5c;padding-left: 4%">成为代理商最少需要{$lowMoney}元</span><br/><br/>
                </div>
                <div class="am-u-sm-12" align="center">
                    <button type="button" onclick="jumpRecharge()" class="am-btn am-round" style="background-color: #FFAD01;color: #fff;width:100%;margin-top: 15px;height: 40px">确认充值</button>
                </div>
           <!--     <div class="am-u-sm-12" align="center" style="font-size: 20px;margin-top: 20px;">
                                    提示
                </div>
                <div style="    width: 100%;margin-top: 35%">
                    <p style="font-size: 16px;line-height: 1.7;padding-left: 15px;color: #5c5c5c">加入代理充值、请务必一次性充值满500元以上、不可分开多次充值，分开充值将不进行累计！</p>

                </div>-->
            </form>
        </div>
    </div>
</div>
</body>

</html>
<script type="text/javascript" src="__PUBLIC__/layer/layer.js"></script>
<script>

    $(function(){

        $('[name=money]').bind('input propertychange', function() {mInfo();});

    });

    function modalInfo(info,success){
        layer.msg(info);
    }
    var lowMoney = {$lowMoney};
    function mInfo(){
        console.info($('[name=money]').val());
        var defaultInfo = "成为代理商最少需要"+ lowMoney;
        var money = $('[name=money]').val();
        if(money == '' || money == 0)
            $('#info').html(defaultInfo);
        else if(money < lowMoney){
            $('#info').html('您还差' + (lowMoney - money) + '元就能成为代理');
        }
        else if(money >= lowMoney){
            $('#info').html('恭喜您即将成为代理商');

        }
    }

    function jumpRecharge(){
        var money = $('[name=money]').val();
        if(money <= 0) {
            layer.msg('请输入正确金额');
            return ;
        }
        window.location.href = 'http://www.jipintc.com/Home/ShopCart/recharge?money='+ money;

    }

</script>